<?php

class Teacher_Model_DbTable_Skill extends Zend_Db_Table_Abstract
{

    protected $_name = 'skills';

    public function getAll(){
    	return $this->fetchAll();
    }
    
    public function getByID($id){
    	return $this->fetchRow("skill_id = $id");
    }
    
    public function addNew($sName){
    	$data = array(
    			'skill_name'=>$sName,
    			"status"=>0
    			);
    	return $this->insert($data);
    }
    
    public function updateSkill($id,$sName){
    	$data = array(
    			'skill_name'=>$sName,
    			"status"=>0
    	);
    	return $this->update($data, "skill_id = $id");
    }

}

